﻿Imports System.Web
Imports System.Web.Services
Imports System.Web.Services.Protocols
Imports Cdm.DataCore.LookupTables

' To allow this Web Service to be called from script, using ASP.NET AJAX, uncomment the following line.
' <System.Web.Script.Services.ScriptService()> _
<WebService(Namespace:="http://tempuri.org/")> _
<WebServiceBinding(ConformsTo:=WsiProfiles.BasicProfile1_1)> _
<System.Web.Script.Services.ScriptService()> _
<Global.Microsoft.VisualBasic.CompilerServices.DesignerGenerated()> _
Public Class AutoCompleteAdHoc
    Inherits System.Web.Services.WebService

    <WebMethod(EnableSession:=True)> _
    Public Function CaseStatus(ByVal prefixText As String, ByVal count As Integer) As String()
        Return GetSearchResult("CaseStatus", prefixText, count)
    End Function

    <WebMethod(EnableSession:=True)> _
        Public Function County(ByVal prefixText As String, ByVal count As Integer) As String()
        Return GetSearchResult("County", prefixText, count)
    End Function
    <WebMethod(EnableSession:=True)> _
    Public Function FMSA(ByVal prefixText As String, ByVal count As Integer) As String()
        Return GetSearchResult("FMSA", prefixText, count)
    End Function

    <WebMethod(EnableSession:=True)> _
    Public Function SupportBrokerAgency(ByVal prefixText As String, ByVal count As Integer) As String()
        Return GetSearchResult("SupportBrokerAgency", prefixText, count)
    End Function

    <WebMethod(EnableSession:=True)> _
 Public Function Gender(ByVal prefixText As String, ByVal count As Integer) As String()
        Return GetSearchResult("Gender", prefixText, count)
    End Function

    <WebMethod(EnableSession:=True)> _
Public Function Race(ByVal prefixText As String, ByVal count As Integer) As String()
        Return GetSearchResult("Race", prefixText, count)
    End Function

    <WebMethod(EnableSession:=True)> _
Public Function LocalProgramName(ByVal prefixText As String, ByVal count As Integer) As String()
        Return GetSearchResult("Race", prefixText, count)
    End Function


    Private Function GetSearchResult(ByVal searchType As String, ByVal prefixText As String, ByVal count As Integer) As String()
        Return LookupObjectGeneric.AdHocSearch(searchType, prefixText, count)
    End Function

End Class
